var Mammal = {
	name: '',
	get_name: function(){
		return this.name;
	},
	set_name: function(iname){
		this.name = iname;
	},
	say: function(){
		console.log(this.name);
	}
};


var Animal = function(){
	this.name = '';
};

Animal.prototype.get_name = function(){
	return this.name;
};

Animal.prototype.set_name = function(name){
	this.name = name;
};

Animal.prototype.say = function(){
	console.log(this.name);
};

var animal = new Animal();
animal.set_name("Dog");
animal.say();

var Cat = function(){
};

Cat.prototype = new Animal();
Cat.prototype.run = function(){
	for(var i = 0; i< 10; i++){
		console.log("I am running");
	}
};

var myCat = new Cat();
myCat.set_name("Cat");
myCat.say();
myCat.run();